package testDriver;

import hibernate.DAOLastSnapshot;
import hibernate.DTOLastSnapshotList;
import hibernate.LastSnapshot;

import java.util.List;
/*
 * Des stations ont-elles changé de nombre de bornes ?
 */
public class TestingQuestion3 
{
	public static final int MAX_DISPLAY = 5;

	public static void main(String[] args) {

		DAOLastSnapshot daoLastSnapshot = new DAOLastSnapshot();
		DTOLastSnapshotList dtoLastSnapshotList = daoLastSnapshot
				.getChangedCapacityStation();
		List<LastSnapshot> list = dtoLastSnapshotList.getLastSnapshotList();
		int count = 0;
		if (list != null) 
		{
			System.out.println("Des stations ont changé de nombre de bornes:");
			for (LastSnapshot i : list) 
			{
				System.out.println(i.toString());
				count++;
				if (count == MAX_DISPLAY)
					break;
			}
		}
	}
}
